<form action="{{url}}" class="learning_outcome" method="post">

  <label class="span3" for="title">{{#t "title"}}Name this outcome{{/t}}:</label>
  <input class="outcome_title span3" name="title" id=title size="50" type="text" value="{{title}}" placeholder="{{#t}}New Outcome{{/t}}">

  <label class="span3" for="display_name">{{#t "display_name"}}Friendly name (optional){{/t}}:</label>
  <input class="outcome_display_name span3" name="display_name" id=display_name size="50" type="text" value="{{display_name}}">

  <label for="description">{{#t "description"}}Describe this outcome{{/t}}:</label>

  <div style="float: right;">
    <a href="#" class="rte_switch_views_link">
      {{t "HTML Editor"}}
    </a>
    <a href="#" class="rte_switch_views_link" style="display:none;">
      {{t "Rich Content Editor"}}
    </a>
  </div>
  <div style="clear:both;"></div>

  <textarea cols="40" name="description" id=description rows="20" style="display: none; width: 100%; height: 150px;">{{description}}</textarea>

  <div id="outcome_criterion_dialog" style="display: none;">
    {{#t "criterion_dialog"}}Learning outcomes can be included in assignment rubrics as an easy way
    to assess mastery of outcomes aligned to specific assignments.  When you define
    a learning outcome, you should also define a criterion that can be used
    when building assignment rubrics.  Define as many rubric columns as you
    need, and specify a point threshold that will be used to define mastery
    of this outcome.{{/t}}
  </div>

  <label>
    {{#t "criterion"}}Criterion ratings{{/t}}:
    <a class="outcome_information_link" title="{{#t "criterion_info_link"}}Click to learn about criterion ratings{{/t}}" tabindex=0 href="#"><i class="icon-question"></i></a>
  </label>
  <table class="criterion">
    <tbody>
      <tr>
        {{#eachWithIndex ratings}}
          {{> [outcomes/criterion]}}
        {{/eachWithIndex}}
       <td class="total">
         <h5 class="total">{{#t "total_points"}}Total Points{{/t}}</h5>
         <div class="points_possible">
           {{#t}}{{n points_possible precision=2 strip_insignificant_zeros=true}} Points{{/t}}
         </div>
       </td>
      </tr>
    </tbody>
  </table>
  <div>
    <label for="mastery_points" style="display: inline">{{#t "mastery"}}Mastery at{{/t}}:</label>
    <input type="text" name="mastery_points" style="width: 20px;" class="mastery_points" id="mastery_points" value="{{n mastery_points precision=2 strip_insignificant_zeros=true}}">
  </div>
  <div>
    <label for="calculation_method" style="display: inline">{{#t "calculation_method"}}Calculation Method{{/t}}:</label>
    <select name="calculation_method" class="calculation_method" id="calculation_method" data-calculation-method="{{calculation_method}}" value="{{calculation_method}}">
      {{#each calculationMethods}}
        <option value="{{@key}}" {{ selectedIf @key ../calculation_method }}>
          {{friendlyCalculationMethod}}
        </option>
      {{/each}}
    </select>
  </div>
  <div class="content-box">
    <div class="grid-row">
      <!-- Hook for OutcomeCalculationMethodFormView -->
      <div class="col-xs-12 outcome-calculation-method-form"></div>
    </div>
  </div>
  <div class="align-right">
    <button type="button" class="btn cancel_button">{{#t "#buttons.cancel"}}Cancel{{/t}}</button>
    <button type="submit" class="btn btn-primary submit_button">{{#t "#buttons.save"}}Save{{/t}}</button>
  </div>
</form>
